/*
 * @Author: doing
 * @Date: 2023-08-22 10:25:47
 * @LastEditors: git config user.name && git config user.email
 * @LastEditTime: 2023-08-26 17:57:58
 * @FilePath: \background-management-system\src\api\member.js
 * @Description: 
 * 成员api接口
 * Copyright (c) 2023 by 1540265624@qq.com, All Rights Reserved. 
 */
import axios from '~/axios'
//查找用户信息(不传递默认查找全部)
export function searchMember(body){
    return axios.post('/user/member/search',body)
}

//添加用户
export function addMember(body){
    return axios.post('/user/member',body)
}

//更新用户
export function updataMember(body){
    return axios.put('/user/member',body)
}

//根据id删除成员信息
export function deleteMember(id){
    return axios.delete(`/user/member/${id}`)
}

//上传图片接口 data直接是FormData对象
export function uploadPic(body){
    return axios.post('/content/file/upload',body)
}

//删除图片接口
export function deletePic(fileUrl){
    return axios.delete('/content/file/delete',{
        params:{
            fileUrl
        }
    })
}


